<?php  
header('Content-Type: application/rss+xml; charset=utf-8');
?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>VACOSI MAKEUP HOUSE - VACOSI.COM</title>
		<description>Cung cấp sỉ và lẻ các sản phẩm makeup, dụng cụ trang điểm, tóc, nail...</description>
		<link>http://www.vacosi.com</link>
		<atom:link href="http://www.vacosi.com/vacosi.rss" rel="self" type="application/rss+xml" />
<?php
	$now = date('D, d M Y H:i:s O',time());
?>
		<lastBuildDate><?php echo $now;?></lastBuildDate>
		<generator>WKS CMS</generator>
		<language>vi-vn</language>
<?php		
foreach($product_arr as $value)
{
	$productURL = ProductUrl($value);
	$price = FormatPrice($value['product_min_price']);
	
	//$des = str_replace('</li>', '. ', $value['product_des_short']);
	//$des = strip_tags($des);
	$time = date('D, d M Y H:i:s O',strtotime($value['product_date']));
	
	echo"<item>";
	echo"	<title>{$value['product_name']}</title>";
	echo"	<link>$productURL</link>";
	echo"	<guid>$productURL</guid>";
	$imgURL = BASE_URL. $value['product_img'];
	echo"	<description><![CDATA[Giá từ: $price VNĐ - <img src='$imgURL' align='left' style='margin-right:5px;width:85px;height:85px'/>{$value['product_des_short']}]]></description>";
	echo"	<author>info@sosanh.info (So sánh giá)</author>";
	echo"	<category>frontpage</category>";
	echo"	<pubDate>$time</pubDate>";
	echo"</item>";
}
?>
	</channel>
</rss>
